package finalproject.model.rooms;

import finalproject.model.player.Energy;
import finalproject.model.player.Player;
import finalproject.view.StringManager;

/**
 * PetClinic is a room in which the player's pet can regain their energy
 * 
 * @author Shafiq Daniel
 */
public class PetClinic extends Room {

	// the energy to be added at each player interaction
	private static final int ENERGY_ADD = 5;
	
	public PetClinic(String description, boolean isLighted) {
		super(description, isLighted);
		// TODO Auto-generated constructor stub
	}

	@Override
	public boolean prepareActivity(Player p) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean doActivity(Player p) {
		// TODO Auto-generated method stub
		Energy petEnergy = p.getPet().getBadge().getEnergie();
		
		if(petEnergy.isMax()){
			StringManager.outPut("petalreadymaxenergy");
			return false;
		}
		else{
			p.getPet().getBadge().modifierEnergie(ENERGY_ADD);
			StringManager.outPut("petaddenergy");
			return true;
		}			
	}
}
